import {DataTypes} from "sequelize";
import _user from './model/t_user.js';
import _captcha from './model/t_captcha.js';
import _captcha_new from './model/t_captcha_new.js';
// 自动生成mysql 然后返回函数生成的模型
function initModels(sequelize) {
  const user = _user(sequelize, DataTypes);
  const captcha = _captcha(sequelize, DataTypes);
  const captchaNew = _captcha_new(sequelize, DataTypes);
  user.sync();
  captcha.sync();
  captchaNew.sync();
  return {
    user,
    captcha,
    captchaNew
  };
}
export default initModels;
